package com.huizu.project.config;

import org.springframework.context.annotation.Configuration;
import org.springframework.web.servlet.config.annotation.InterceptorRegistry;
import org.springframework.web.servlet.config.annotation.WebMvcConfigurer;


@Configuration
public class WebMvcConfig implements WebMvcConfigurer {

    @Override
    public void addInterceptors(InterceptorRegistry registry) {
        // 注册 JwtInterceptor 拦截器，并设置拦截规则
        registry.addInterceptor(new JwtInterceptor())
                .addPathPatterns("/api/prouser/**")
                .excludePathPatterns("/api/proclassify/**");//分类列表放行;

    }
}
